﻿using System;

namespace enyo
{
    /// <summary>
    /// A component that allows you to play sound effects or other audio resources. This component is an abstraction of HTML 5 Audio object.
    /// </summary>
    public class Sound : Component
    {
        /// <summary>
        /// URL of the sound file to play. Can be relative to the application's HTML file.
        /// </summary>
        public string Src { get; set; }

        /// <summary>
        /// If true, loads the sound file when the control is created, trading increased network/memory usage for decreased latency.
        /// </summary>
        public bool Preload { get; set; }

        /// <summary>
        /// (webOS only) Sound channel through which audio is played. 
        /// Default channel is "defaultapp", which is used for application sounds. Use "media" for playback of music.
        /// </summary>
        public string/*TODO:Type->defaultapp,media*/ AudioClass { get; set; }


        /// <summary>
        /// Plays the sound. If the sound is already playing, playback restarts at the beginning.
        /// </summary>
        public void Play()
        {
        }

    }
}
